<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>捕获页面DOM内容</title>
    <script src="./res/jquery-3.5.1.min.js"></script>
</head>

<body>
    <input type="text" style="display: block; width: 300px; height: 30px; border: #abcdef solid 1px;border-radius: 5px;" value="" autocomplete="off">
    <span id="content"></span>
</body>

</html>
<script>
    $(function(e) {
        $('input').keyup(function(e) {
            $('#content').text($('input').val());
        });
    });
</script>